The present invention relates to an image processing apparatus.
In image processing, performing compression on, e.g., every 4×4 pixels as one block unit produces block edges noise in the horizontal and vertical block boundaries of the four sides surrounding the block. To remove this block edges noise, a deblocking filtering process is performed to make the block boundaries inconspicuous.
Pixels are classified into a Y image (luma component), Cb image (chroma component Cb), and Cr image (chroma component Cr), and the deblocking filtering process must be performed on the vertical and horizontal block boundaries of a block including 4×4 pixels as a minimum unit for each of the Y, Cb, and Cr images.
For example, the deblocking filtering process is performed on one vertical block boundary of a block including 4×4 pixels by using data stored in a total of eight pixels arranged four by four on the right and left sides of this vertical block boundary.
First, the data of a total of eight pixels of one vertical block boundary are added to obtain, e.g., an average value, and the pixel data of the eight pixels are corrected by using this average value. This makes it possible to eliminate the discontinuity of data existing in the vertical block boundary.
The deblocking filtering process is performed on the block boundaries of four pixels existing in the vertical block boundaries by performing the above operation four times in the vertical direction.
After that, the deblocking filtering process is similarly performed on one horizontal block boundary of the block. This process uses data stored in a total of eight pixels arranged four by four above and below the horizontal block boundary.
Then, as in the case of the vertical direction, an average value, for example, is obtained from the data of a total of eight pixels of one horizontal block boundary, and the pixel data of the eight pixels are corrected by using this average value. Consequently, the discontinuity of data existing in the horizontal block boundary can be eliminated.
The deblocking filtering process is performed on the block boundaries of four pixels existing in the horizontal block boundaries by performing the above operation four times in the horizontal direction.
The above operations in the vertical and horizontal directions are executed for each of the Y, Cb, and Cr images, thereby completing the deblocking filtering process of the block including 4×4 pixels.
As described above, the processing amount of the deblocking filtering process is large. Also, when H.264 is used as coding standards, the standards define the deblocking filtering process having a large processing amount. In addition, the processing amount of the deblocking filtering process itself is larger than those of the existing coding standards because the block size is 4×4 pixels, i.e., smaller than 8×8 pixels of MPEG-4. That is, the amount of processing performed on the entire image is at least fourfold. Furthermore, the number of pixels increases as the TV screen size increases, so a demand has arisen for image processing corresponding to the increased number of pixels. This also increases the processing amount of the deblocking filtering process.
For this reason, it is expected to increase the processing efficiency of the deblocking filtering process by using pipeline processing.
When continuously performing the deblocking filtering process on, e.g., the vertical block boundaries of the Y image, however, unless all pixels in a vertical block boundary currently being processed by the deblocking filtering process are completely processed, values to be used in the next adjacent vertical block boundary are undetermined. This is so because there is a dependence on data. This makes it impossible to continuously execute the deblocking filtering process on the next adjacent vertical block boundary.
Accordingly, even when the number of pipeline stages is increased by using pipeline processing in the deblocking filtering process, a pipeline stall occurs, and this lowers the processing efficiency.
As has been explained above, the processing amount of the H.264 deblocking filtering process is very large, so it is desirable to increase the processing efficiency by using pipeline processing. However, it is still difficult to increase the processing efficiency of the deblocking filtering process even if the number of pipeline stages increases.
Furthermore, when accessing a memory storing image data, complicated processing is necessary to successively read out the image data in either the vertical or horizontal direction of the image. Memory access apparatuses for solving this problem are also disclosed (e.g., patent references 1 and 2).
Unfortunately, these memory access apparatuses require new registers, and cannot increase the processing efficiency of the deblocking filtering process.    Patent reference 1: Japanese Patent Laid-Open No. 6-342467    Patent reference 2: Japanese Patent Laid-Open No. 59-109969